$OpenBSD: patch-gitweb_gitweb_perl,v 1.26 2015/01/13 09:40:56 benoit Exp $

This prevents the following error: '-T and -B not implemented on filehandles'

--- gitweb/gitweb.perl.orig	Mon Jan 12 23:25:03 2015
+++ gitweb/gitweb.perl	Tue Jan 13 09:28:37 2015
@@ -6985,7 +6985,7 @@ sub git_blob_plain {
 		$expires = "+1d";
 	}
 
-	open my $fd, "-|", git_cmd(), "cat-file", "blob", $hash
+	open my $fd, "-|:raw:perlio", git_cmd(), "cat-file", "blob", $hash
 		or die_error(500, "Open git-cat-file blob '$hash' failed");
 
 	# content-type (can include charset)
@@ -7047,7 +7047,7 @@ sub git_blob {
 	}
 
 	my $have_blame = gitweb_check_feature('blame');
-	open my $fd, "-|", git_cmd(), "cat-file", "blob", $hash
+	open my $fd, "-|:raw:perlio", git_cmd(), "cat-file", "blob", $hash
 		or die_error(500, "Couldn't cat $file_name, $hash");
 	my $mimetype = blob_mimetype($fd, $file_name);
 	# use 'blob_plain' (aka 'raw') view for files that cannot be displayed
